import type { RouteRecordRaw } from 'vue-router'

import Layout from '@/layout/index.vue'
import { PageEnum } from '../enums/pageEnum'
export const LAYOUT = () => Promise.resolve(Layout)

export const INDEX_ROUTE_NAME = Symbol()


export const constantRoutes: Array<RouteRecordRaw> = [
    {
        path:PageEnum.NOT_FOUND,
        component: () => import('@/views/error/404.vue'),
        name: '404',
    },
    {
        path:PageEnum.LOGIN,
        component: () => import('@/views/account/login.vue'),
        name: 'login',
    }
]

export const INDEX_ROUTE: RouteRecordRaw = {
    path:PageEnum.HOME,
    component: LAYOUT,
    name: INDEX_ROUTE_NAME,
}
